namespace NTrace
{
    using System;

    public class PreprocessorException : Exception
    {
        public PreprocessorErrors ErrorNumber { get; set;}
        public int StartLine { get; set; }
        public int StartColumn { get; set; }
        public int EndLine { get; set; }
        public int EndColumn { get; set; }
        public String File { get; set; }

        public PreprocessorException(PreprocessorErrors errorCode, String description)
            : base(description)
        {
            this.ErrorNumber = errorCode;
        }

        public String ErrorCode
        {
            get
            {
                return String.Format("NTRC{0:D4}", (int)this.ErrorNumber);
            }
        }
    }
}
